<h1><%= title "Editing #{@duchy.name}" %></h1>

<% form_for(@duchy) do |f| %>
  <%= f.error_messages %>

  <p>
		<%= f.label :name %><br />
    <%= f.text_field :name %>
  </p>
  <p>
		<%= f.label :kingdom_id %><br />
    	<select name="duchy[kingdom_id]">
		<%= options_kingdom_select @duchy.kingdom_id %>
		</select>
  </p>
  <p>
		<%= f.label :flag %><br />
    <%= f.text_field :flag %>
  </p>
  <p>
    <%= f.submit "Update" %>
  </p>
<% end %>

<%= link_to 'Show', @duchy %> |
<%= link_to 'Back', duchies_path %>